const Mock = require("mockjs")
let data = Mock.mock({
    "list|4": [{
        title: "@ctitle(2)",
        "title1|1": ['都市', '玄幻', '科幻', '历史'],
        "child|8": [{
            bookname: "@ctitle(4,8)",
            img: "@image(30x50,@color)",
            desc: "@cword(8,15)"
        }]
    }]
})

module.exports = {
    devServer:{
        before(app){
            app.get("/list",(req,res)=>{
                res.send(data.list)
            })
        }
    }
}